/*
 * TitledData.h
 *
 *  Created on: Jan 5, 2009
 *      Author: sez
 */

#ifndef TITLEDDATA_H_
#define TITLEDDATA_H_

#include <QString>

class TitledData
{
public:
    TitledData(const QString &title = QString());
    TitledData(const TitledData &orig);
    virtual ~TitledData();
    QString title() const { return mTitle; }
    void setTitle(const QString &title) { mTitle = title; }
    bool operator==(const TitledData &rhs) { return (mTitle == rhs.title()); }
    TitledData &operator=(const TitledData &rhs);
    virtual QString description() const = 0;
    virtual QString summary() const;
    virtual void saveToXml() const = 0;
    virtual void loadFromXml() = 0;
private:
    QString mTitle;
};

#endif /* TITLEDDATA_H_ */
